Silk Mobile

Table of Contents (Homepage)

Configuring Integration Of Jenkins Reports

As part of the Silk Mobile's integration with Jenkins, a post-build action is supported which enables loading the generated HTML execution reports.

Installation

Step 1: Download the Silk_ReportLinks.hpi file from http://supportline.microfocus.com/

Step 2: After downloading the .hpi file, place it in your Jenkins plugins folder (directly under the root of the Jenkins installation folder, which is usually - C:\Program Files (x86)\Jenkins\plugins).

Step 3: Restart your Jenkins server.

Configuring Your Build

Step 1: In your project tab, in the Jenkins portal, click on 'Configure'.

images/download/attachments/3310150/Configure1.png

Step 2: Click on 'Add post-build action', select 'Report Links' (choose the first option) and click on 'Add'.

images/download/attachments/3310150/postbuild3.PNG

Step 3: The following configuration dialog box is now displayed. Make sure to place the build.xml at the same level as the src folder in your Java project.

images/download/attachments/3310150/postbuild4.PNG

images/s/en_GB/5983/f3e491afc761ac0a6981cfa3dcbc04fc7e88c149.52/_/images/icons/emoticons/warning.png The 'report' folder does not exist in the project at this point, that is why the 'No such directory' error is displayed. The first report's generation invokes the folder generation.

Step 4: When entering details into this dialog box, pay particular attention when designating the directory to archive. This directory is relative to the tests project home directory, meaning that you will need to generate the reports to this directory. For example, below is a such a designation in Java:

@Before
public void setUp(){
client = new Client(host, port, true);
client.setProjectBaseDirectory(projectBaseDirectory);
File reports = newFile(System.getProperty("user.dir"), "reports");
reports.mkdirs();
client.setReporter("xml", reports.getAbsolutePath(), "<Your_Test_Name>");
}
  • In this example, the reports directory is set to the project home directory by contacting the user.dir with the reports directory.


Step 5: Run Silk Mobile as an administrator.

Step 6: Schedule a build though Jenkins.

Step 7: After executing the project, the summery report will be available as part of your Jenkins project tab under - 'Report Links'.

images/download/attachments/3310150/image2015-8-20%2015_27_55.png